<%--
  Created by IntelliJ IDEA.
  User: 张皓然
  Date: 2019/4/24
  Time: 21:35
  To change this template use File | Settings | File Templates.
--%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<%@ page language="java" contentType="text/html; charset=UTF-8"
         pageEncoding="UTF-8"%>
<!DOCTYPE html>
<html>
<head>
    <%@include file="/WEB-INF/jspf/meta/meta.jspf"%>
    <title>班级管理</title>
    <%@include file="/WEB-INF/jspf/adminPage.jspf"%>
    <script type="text/javascript"  src="<%=request.getContextPath()%>/static/classroom/classroom.js"></script>

    <script type="text/javascript">

    </script>
</head>
<body>

<!-- 显示信息表格 -->
<table id="dg_classroom" class="easyui-datagrid" pagination="true"
       pageList="[5,10,50,100,200,300,500]" pageSize="5"
       data-options="
                    fit:true
                    ,url:'<%=request.getContextPath()%>/classroom/selectAllClassroom.json'
                    ,fitColumns:false
                    ,singleSelect:true
                    ,toolbar:'#tb'						<%--数据网格(DataGrid)面板的头部工具栏--%>
                    ,onRowContextMenu:f_contextMenu_classroom		<%--鼠标右键事件--%>
                    ">
    <thead>
    <tr>
        <th data-options="field:'classroomId',width:100" checkbox="true">教室ID</th>
        <th data-options="field:'classroomName',width:200,align:'center',sortable:true">教室名称</th>
        <th data-options="field:'classroomInfo',width:200,align:'center'">教室备注</th>
    </tr>
    </thead>
</table>

<!-- 工具栏使用 -->
<div id="tb" style="padding: 5px; height: auto">
    <div>
        <c:if test="${code.contains('classroom:dell')}">
        <a href="#" class="easyui-linkbutton"  iconCls="icon-remove" onclick="$('#dlg_dell').dialog('open')">删除</a>
        </c:if>

        <c:if test="${code.contains('classroom:update')}">
        <a href="#" class="easyui-linkbutton" iconCls="icon-edit" onclick="f_classroom_update()">修改</a>
        </c:if>
        &nbsp;&nbsp;&nbsp;  <%-- 占位符 --%>
<%--        <a href="#" class="easyui-linkbutton" iconCls="icon-search"   onclick="$('#win').window('open')">查询</a>--%>
    </div>
</div>



<!--DataGrid行 右键菜单
    //菜单入口
    function f_contextMenu_subject()
-->
<%@include file="/WEB-INF/jsp/classroom/_menuGrid.jspf"%>

<!-- 删除对话框架 及后台数据处理
     "$('#dlg').dialog('open')  打开对话框架
     "$('#dlg').dialog('close') 关闭对话框架
-->
<%@include file="/WEB-INF/jsp/classroom/_dell.jspf"%>

<!--修改对话框架 及后台数据处理
    启动入口
    function f_subject_update()
-->
<%@include file="/WEB-INF/jsp/classroom/_update.jspf"%>

<!--修改对话框架 及后台数据处理
    启动入口
    function f_subject_oneDetail()
-->
<%@include file="/WEB-INF/jsp/classroom/_oneDetail.jspf"%>
</body>
</html>
